'use client'

import { useParams } from 'next/navigation'

// 应用ID到应用key的映射
const APP_ID_TO_KEY: Record<string, string> = {
  '1': 'chatgpt',
  '2': 'claude',
  '3': 'gemini',
  '4': 'qianwen',
  '5': 'baichuan',
  '6': 'deepresearch',
  '7': 'writer',
  '8': 'translator',
  '9': 'coder'
}

export default function InstalledAppPage() {
  const params = useParams()
  const appId = params.appId as string
  const appKey = APP_ID_TO_KEY[appId]

  if (!appKey) {
    return <div className="p-6">应用不存在</div>
  }

  return (
    <div className="h-full flex flex-col">
      <div className="flex-1 overflow-y-auto">
        {/* 消息列表将在这里显示 */}
      </div>
    </div>
  )
}
